﻿<UserControl x:Class="music_control.MusicPluginChromeOptions"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:extToolkit="http://schemas.microsoft.com/winfx/2006/xaml/presentation/toolkit/extended"
             mc:Ignorable="d"
               >
    <StackPanel>
        <GroupBox Header="Chrome Server Options">

            <Grid>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition/>
                    <ColumnDefinition/>
                    <ColumnDefinition Width="16"/>
                </Grid.ColumnDefinitions>
                <Grid.RowDefinitions>
                    <RowDefinition/>
                    <RowDefinition/>
                    <RowDefinition/>
                </Grid.RowDefinitions>

                <TextBlock Margin="5" Grid.Row="0" Grid.Column="0" Text="Server port"/>

                <extToolkit:IntegerUpDown Margin="5" Grid.Column="1" Grid.Row="0" Minimum="0" Value="{Binding Port}" Width="70" HorizontalAlignment="Left" />

                <Image Grid.Column="2" Grid.Row="0" Height="16" Width="16" Source="/music-control;component/Icons/information.png" ToolTipService.ShowDuration="10000">
                    <Image.ToolTip>
                        <ToolTip>
                            <StackPanel>
                                <TextBlock FontWeight="Bold">Port</TextBlock>
                                <TextBlock>The server started with this port. This port should be the same as it is in the music control Chrome Addon.</TextBlock>
                            </StackPanel>
                        </ToolTip>
                    </Image.ToolTip>
                </Image>

                <TextBlock Margin="5" Grid.Row="1" Grid.Column="0" Text="Server state"/>

                <TextBlock Margin="5" Grid.Column="1" Grid.Row="1" Text="{Binding ServerState}" HorizontalAlignment="Left" TextWrapping="Wrap" />

                <Image Grid.Column="2" Grid.Row="1" Height="16" Width="16" Source="/music-control;component/Icons/information.png" ToolTipService.ShowDuration="10000">
                    <Image.ToolTip>
                        <ToolTip>
                            <StackPanel>
                                <TextBlock FontWeight="Bold">Serverstate</TextBlock>
                                <TextBlock>Indicate the state of the server.</TextBlock>
                            </StackPanel>
                        </ToolTip>
                    </Image.ToolTip>
                </Image>

                <TextBlock Margin="5" Grid.Row="2" Grid.Column="0" Text="Connection state"/>

                <TextBlock Margin="5" Grid.Column="1" Grid.Row="2" Text="{Binding ConnectionState}" HorizontalAlignment="Left" TextWrapping="Wrap" />

                <Image Grid.Column="2" Grid.Row="2" Height="16" Width="16" Source="/music-control;component/Icons/information.png" ToolTipService.ShowDuration="10000">
                    <Image.ToolTip>
                        <ToolTip>
                            <StackPanel>
                                <TextBlock FontWeight="Bold">Connection state</TextBlock>
                                <TextBlock>Indicate if the server is connected to the Chrome addon.</TextBlock>
                            </StackPanel>
                        </ToolTip>
                    </Image.ToolTip>
                </Image>

            </Grid>
        </GroupBox>
    </StackPanel>
</UserControl>
